Repository navigation
fix(release): collect the changelog in its own job, via a PR when pushes are refused - #388
Merged
Merged
Conversation
…hes are refused Changelog collection was the last step of create-release, before the step that writes release-created. A ruleset refusal (GH013) failed the job before that output existed, so publish-github-packages and update-floating-tags skipped a release that was otherwise complete. Move it to a collect-changelog job after create-release. Keep the direct push; on a protection refusal open a changelog/collect-<version> PR with the CI App token (falling back to the PAT, then GITHUB_TOKEN) and enable rebase auto-merge so a merge queue takes it. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_011To9HQJLrCH6wYa5WCpw3L
This was referenced Nov 6, 2026
Merged
…ock floating tags Review of #388: update-floating-tags had no status function, so an implicit success() and the skipped build-* jobs skipped it on every release. Give it and collect-changelog !cancelled(). Collect: decide whether to collect before minting a token; skip a release not cut from the default branch; refuse while an earlier changelog PR is open; check the commit touches only the changelog; cherry-pick it onto a fresh fetch of the default branch for both the direct push and the PR; open the PR with the App token or the PAT only; fall back to a plain rebase merge when auto-merge cannot be enabled. build-status waits for the job. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_011To9HQJLrCH6wYa5WCpw3L
…d to the pushed commit gh pr merge <branch> resolves by head name, which a fork PR can share. Look the PR up with isCrossRepository == false, merge it by number with --match-head-commit, and filter the pending-PR guard the same way. The plain-merge fallback stays (it never passes --admin) but is pinned the same way. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_011To9HQJLrCH6wYa5WCpw3L
…ch; leave floating tags alone Re-review of #388. Comparing github.ref_name to the default branch skipped every tag-push release (burndown-runner-image), so test ancestry instead. The pending-PR guard lists up to 1000 PRs, skips this version's own branch so a re-run reuses its PR, and only warns when the token cannot list PRs. Revert the !cancelled() on update-floating-tags: the job has never run for callers with skipped build-* jobs, and turning it on makes annotated v0/v0.N tags on the release commit that git describe prefers over vX.Y.Z (audiobook-organizer stamps builds from git describe). Whether floating tags become an input is a separate decision. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_011To9HQJLrCH6wYa5WCpw3L
jdfalk
added a commit
that referenced
this pull request
Nov 6, 2026
…ock floating tags Review of #388: update-floating-tags had no status function, so an implicit success() and the skipped build-* jobs skipped it on every release. Give it and collect-changelog !cancelled(). Collect: decide whether to collect before minting a token; skip a release not cut from the default branch; refuse while an earlier changelog PR is open; check the commit touches only the changelog; cherry-pick it onto a fresh fetch of the default branch for both the direct push and the PR; open the PR with the App token or the PAT only; fall back to a plain rebase merge when auto-merge cannot be enabled. build-status waits for the job. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_011To9HQJLrCH6wYa5WCpw3L
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Why
audiobook-organizer's production release v0.223.0 (run 42228750978) created its release and every asset. Then Create GitHub Release failed with
GH013: Repository rule violations found for refs/heads/mainwhen it pushed the collectedCHANGELOG.md. That repo now has a merge-queue ruleset with no bypass. The collect step ran ahead ofcheck-release, which writesrelease-created, so Publish GitHub Packages was skipped.Change (
reusable-release.yml)collect-changelog, which runs aftercreate-release(!cancelled()andrelease-created == 'true'). A failure there turns the run red but no longer skips publishing.build-statuswaits for it.planstep decides whether to collect before any token is minted. It requires all of these:merge-base --is-ancestor, so a tag-push release on main still collects);scriv.iniexists andCHANGELOG.mdhas its marker;CHANGELOG.mdandchangelog.d/. It then cherry-picks that one commit onto a fresh fetch of the default branch. The old step pushed or rebased the checkout's own history, so a release cut from another branch could carry that branch's commits.changelog/collect-<version>:CI_APP_IDApp token, orJF_CI_GH_PAT. NotGITHUB_TOKEN, because a PR opened with it starts no checks.isCrossRepository == false, and merged with--match-head-commit.--rebase --autofirst, falling back to a plain--rebasemerge (never--admin).[skip ci]; the title carries[skip changelog].Not changed:
update-floating-tagsIt is still skipped whenever
build-*jobs are skipped, because itsif:has no status function. That's existing behaviour and isn't caused by the changelog failure. Turning it on would create annotatedv0/v0.Ntags on each release commit.git describeprefers those overvX.Y.Z, which would change audiobook-organizer's build version stamps. Whether it becomes an opt-in input is a separate decision.Review
An independent agent reviewed this in two rounds; both rounds' findings are addressed in these commits. A security review also checked it: it flagged carrying history across and resolving PRs by head name, and both are fixed.
actionlintis clean.Test plan
collect-changelogopens and auto-merges a PR, andpublish-github-packagesruns.🤖 Generated with Claude Code
https://claude.ai/code/session_011To9HQJLrCH6wYa5WCpw3L